package com.allyes.flume.interceptor.parser;

import com.allyes.flume.interceptor.DynamicRawlogEventHeader;
import com.allyes.flume.interceptor.InvalidLogHandler;
import com.allyes.flume.source.Pair;
import org.apache.flume.Event;

import java.io.IOException;

/**
 * Created by gc on 7/14/16.
 */
public abstract class LogParser {
  public static final String LOG_PARSER_AINSIGHT = "ainsight";
  public static final String LOG_PARSER_AIM = "aim";  // ainsight mobile
  public static final String LOG_PARSER_ADX = "adx";
  public static final String LOG_PARSER_DEFAULT = LOG_PARSER_AINSIGHT;

  public static final String PARSER = "log.parser";

  protected InvalidLogHandler invalidLogHandler = null;
  protected DynamicRawlogEventHeader dynamicRawlogEventHeader = null;

  public Pair<Boolean, Event> parseToEvent(
      long inode,
      String fileName,
      int lineIndex,
      String line) throws IOException {
    return null;
  };
}
